package com.ymatou.iapi.selleraccount.service;

import java.io.IOException;
import java.util.ArrayList;

import org.apache.http.client.ClientProtocolException;

import com.google.gson.reflect.TypeToken;
import com.ymatou.iapi.livebuyer.parameter.LiveRoomInfo;
import com.ymatou.iapi.selleraccount.parameter.SellerBaseInfo;
import com.ymt.base.BaseCall;
import com.ymt.core.tool.FormatUtil;
import com.ymttest.utils.EnvSetup;

public class GetSellerBaseInfoCall  extends BaseCall  {
	private static String opurl ="api/SellerQueryV02/GetSellerBaseInfo";
	
	public GetSellerBaseInfoCall() {
		super(EnvSetup.getSystemUrl("selleraccount_iapi"),opurl,"POST","JSON");
	}
	
	public void addDefHeader() {
		client.addHeader("Content-Type", "application/json");
	}
	public SellerBaseInfo getSellerBaseInfo()
    {
		SellerBaseInfo data = null;
        try {
        	String sellerBaseInfo=getJsonObject().get("Data").getAsJsonObject().get("SellerBaseInfo").toString();
        	data=(SellerBaseInfo) FormatUtil.GSONToObject(sellerBaseInfo, SellerBaseInfo.class);
        } catch (Exception e) {
            e.printStackTrace();
        }
        return data;
    }

}
